package com.ea.admin.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ea.admin.pojo.dto.PositionInfoDto;
import com.ea.admin.pojo.po.PositionInfo;
import com.ea.common.mybatis.EmoAnalyBaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface PositionInfoMapper extends EmoAnalyBaseMapper<PositionInfo> {
    boolean checkIfPositionHasUser(
            @Param("positionId") Long positionId
    );

    PositionInfo selectPositionInfoById(
            @Param("positionId") Long positionId
    );

    List<Long> getPositionIdListByAccountId(
            @Param("accountId") Long accountId
    );

    Page<PositionInfoDto> selectPositionPage(
            Page<PositionInfoDto> objectPage,
            @Param("companyIdList") List<Long> companyIdList,
            @Param("positionName") String positionName
    );
}
